# name : proc lifetest for stratified logrank z-stat
# key : logrank.z.stat
# contributor: Shuguang Sun
# --
ods output homtests=${5:km}_testp HomStats=$5_stat LogrankHomCov=$5_cov;

data _${5:km}_stats;
* need to filter loc of matrix by trt;
merge ${5:km}_testp $5_stat(keep=LogRank) $5_cov(keep=cov);
rawz=logrank/sqrt(cov);
run;